package com.x.provider.general.service.cms;

import com.x.core.web.page.PageDomain;
import com.x.core.web.page.PageList;
import com.x.provider.api.general.enums.TopicSourceTypeEnum;
import com.x.provider.api.general.model.dto.cms.TopicListReqDTO;
import com.x.provider.general.model.domain.cms.Topic;
import com.x.provider.general.model.domain.cms.TopicFavorite;


import java.util.List;
import java.util.Optional;

public interface TopicService {
    List<Topic> searchTopic(String keyword);
    Optional<Topic> getTopic(Long id, String title);
    List<Topic> listTopic(List<String> titles, Integer itemType);
    List<Topic> listOrCreateTopics(List<String> topicTitles, Integer itemType);
    void favoriteTopic(Long customerId, Long topicId, Boolean favorite);
    Boolean isFavoriteTopic(Long customerId, Long topicId);
    List<TopicFavorite> listTopicCustomerFavorite(Long customerId, TopicSourceTypeEnum topicSourceTypeEnum);
    List<Topic> listTopic(TopicListReqDTO topicListReqDTO);
    PageList<Topic> listTopic(Long customerId, PageDomain pageDomain);
}
